package com.cloud.controller;

import com.cloud.R;
import com.cloud.service.PaymentFeignService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @BelongsProject: my
 * @BelongsPackage: com.cloud
 * @Author: ji ge
 * @CreateTime: 2024-02-01  12:30
 * @Description: TODO
 * @Version: 1.0
 */
@RestController
@RequestMapping("/consumer")
public class OrderFeignController {
    @Resource
    private PaymentFeignService paymentFeignService;

    @GetMapping("/getPaymentById/{id}")
    public R getPaymentById(@PathVariable("id") Long id) {
        return paymentFeignService.getPaymentById(id);
    }

    @GetMapping("/paymentFeignTimeOut")
    public String paymentFeignTimeOut(){
        return  paymentFeignService.paymentFeignTimeOut();
    }
}
